package cn.bx.bid.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class AppConfig {

    @Bean(name="p1",initMethod = "init",destroyMethod = "destory")
    public Printer findPrinter(){
        return new Printer(1400,"佳能","打印速度快");
    }

    @Bean(name="p2",initMethod = "init",destroyMethod = "destory")
    public Printer findPrinter2(){
        return new Printer(2900,"惠普","牛逼轰轰");
    }
}
